package com.lotter.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import com.lotter.service.ManagerService;

/**
 * 后台管理员管理
 * 
 * @author panguixiang
 * @version $Id: AdminManageController.java, v 0.1 2016年1月8日 上午9:17:30  Exp $
 */
@Controller
@RequestMapping("/adminMange")
public class AdminManageController {
	
	@Autowired
	private ManagerService adminService;

    /**
	 * 
	 * main:(登录成功，进入后台主页). <br/> 
	 *
	 * @author panguixiang
	 * @return
	 * @since JDK 1.7
	 */
	@RequestMapping(value="main", method = RequestMethod.GET)
	public String main(Model model) {
		return "main";
	}
	
	@RequestMapping(value="common", method = RequestMethod.GET)
	public String common(Model model) {
		model.addAttribute("common",adminService.getCommon());
		return "common";
	}
	

}
